Baseball, by the Rules
For more examples, click here, though slight disclaimer in that this appears to only be balls that go entirely out of play; there doesn't seem to be a way to directly search for fly balls that are caught in foul territory.
A Ball in the Air Goes Foul
A ball in the air that goes foul is declared a dead ball as soon as it touches basically anything in foul territory— or once it passes fully out of play. The vast majority of foul balls will land somewhere in the stands, maybe in the form of a towering fly ball that sneaks foul down the line, or a pop-up that arcs directly behind home plate, or maybe a line drive that would cause a serious health hazard to someone, except that it gets corralled by the netting. Indeed, the lower parts of the stands, including behind home plate, have netting that extends down past the bases; this is explicitly to protect fans screaming line drives that get ripped into those areas. Said netting is considered out of play, so if a pop-up touches the netting before making its way to a fielder's glove, it's a foul ball.
Otherwise, though, if the ball stays over the field of play, and a fielder catches it before it hits either the ground, or any part of the stadium, the batter is ruled out. When we talk about “any part of the stadium,” we are usually talking about that netting, but this also applies to fences, railings, and what have you. If a ball touches the netting, or anything else, including a fan, before it gets to a fielder’s glove, it’s a foul ball, and any subsequent catch does not count. If a defender makes a play on a catchable foul ball, but does not make the catch, this can result in a missed catch error.
For balls that land near the line and thus need an umpire to weigh in, that umpire indicates a foul ball by holding his hands up, essentially declaring a dead ball. If the ball lands fair, they will point to fair territory, instead.
Fair/foul calls can only be reviewed by replay if the ball lands “behind” the spot where the base umpires usually stand, so calls further down the first- or third-base lines are reviewable, while calls closer to home plate are not. This is important when you are looking at the difference between a very long foul ball, and home run. Balls that may or may not have hit the net before being caught are always reviewable, as are catches on balls that may have actually hit the ground before being caught.
A ball that goes foul but stays in the playing area must be collected and removed from the field before play resumes. If the count had less than two strikes before the pitch, then the foul ball results in a strike. If there were already two strikes, then the count does not advance on a foul ball— unless, of course, the ball was struck foul by a bunt. A bunted foul ball is always a strike, regardless of the count beforehand.